<!doctype html>
<html>
<head>
    <meta charset="utf-8">
    <title>中搜企悦</title>
    <link href="<{$ipath}>index/style/index_css.css" type="text/css" rel="stylesheet"/>
    <link href="<{$ipath}>index/style/style.css" type="text/css" rel="stylesheet"/>
    <link href="<{$ipath}>index/style/float-manage.css" type="text/css" rel="stylesheet"/>
    <script type="text/javascript"  src="<{$ipath}>public/js/head.js"></script>
    <script src="<{$ipath}>public/js/jquery.js"></script>
    <link href="<{$ipath}>index/style/fuceng.css" type="text/css" rel="stylesheet"/>
    <style>.content{background-color:#edeef2;}.topnav{width:96%;margin:0 auto;padding-top:16px;font-size:15px;line-height:18px;}.topnav *{color:#333;}</style>
    <script>
	function resizeIframe(){
		var iframeid = document.getElementById("to_right"); //iframe id 
		if (document.getElementById) { 
			if (iframeid && !window.opera) { 
				if (iframeid.contentDocument && iframeid.contentDocument.body.offsetHeight) { 
					iframeid.height = iframeid.contentDocument.body.offsetHeight; 
				} else if (iframeid.Document && iframeid.Document.body.scrollHeight) { 
					iframeid.height = iframeid.Document.body.scrollHeight; 
				} 
			} 
		} 
	}

        $(document).ready(function(e) {
           
            /*点击a标签*/
            $(".menu_list .menu_list_small a").click(function(){
                clearclass();
                $(this).addClass("liselect");
		$(this).closest('ul').prev().addClass('pselect');
            });
            function clearclass(){
				$('.p_quan').removeClass('pselect');
                $(".menu_list .menu_list_small a").each(function(index, element) {
                    $(this).removeClass("liselect");
                });
            }
			

            /*下拉菜单伸缩，换图片*/
            $(".ul_hide").hide();
            //默认第一个有颜色
            $('.p_quan').click(function(){
				var _this=$(this);
				if (_this.hasClass('liselect'))
				{
					$('.menu_list .p_quan').removeClass("pselect");
					_this.addClass('liselect')
				}
				if (_this.next('ul').length>0)
				{
					if(_this.hasClass('p_up')){
						_this.siblings().show();
						_this.removeClass('p_up').addClass('p_down');
					}else{
						_this.siblings().hide();
						_this.removeClass('p_down').addClass('p_up');
					}
				}else{
					$('.p_quan').removeClass('pselect');
					$('.menu_list_small a').removeClass('liselect');
					_this.addClass('pselect');
				}
           });

	    //账户下拉
            $(".account_box ul").hide();
            $(".account_box").mouseover(function(e) {
                $(".account_box ul").show();
                $(".account_box").css({"border":"1px solid #c1c1c1","width":"98px"});
            });
            $(".account_box").mouseleave(function(e) {
                $(".account_box ul").hide();
                $(".account_box").css({"border":"none","width":"100px"});
            });
            //旗舰版
            $(".qijian_hide").hide();
            $(".arrow_01").mousemove(function(){
                $(this).attr("src","<{$ipath}>index/images/top_001.png");
                $(".qijian_hide").show();
            })
            $(".arrow_01").mouseleave(function(){
                $(this).attr("src","<{$ipath}>index/images/top_01.png");
                $(".qijian_hide").hide();
            })
			/*楼层弹窗*/
			$(".add_floor").hide();
        });

        //wo xie de

        //弹出层
        function closediv(){
            $(".cd-popup").hide();
            $("#above").hide();
			$(".add_floor").hide();
        }
        function showdiv(str){
           closediv();

            $(".shade").show();
            $("#"+str).show();
            //art.dialog.data('domid', domid);
            //art.dialog.open('?g=user&m=functiondata&a=insert&iskeyword='+iskeyword,{lock:true,title:'插入链接或关键词',width:600,height:400,yesText:'关闭',background: '#000',opacity: 0.45});
        }

        $(function(){
            //alert(1);
            var secs = $('.sec-sort-container');
            //alert(secs.length);
            $('.first-sort li').each(function(index, el) {
                $(this).click(function(event) {
                    $(this).addClass('cur').siblings('li').removeClass('cur');
                    $(this).css({
                        background: ' url(<{$ipath}>index/images/g-arrow.png) no-repeat 90% center'
                        /*borderRight: 'none'*/
                    }).siblings().css({
                        background: ' url(<{$ipath}>index/images/w-arrow.png) no-repeat 90% center'
                        /*borderRight: '1px solid #ddd'*/
                    });
                    secs.eq(index).show().siblings().hide();
                });
            });
           
            $('header i').click(function(event) {
                $('#above').hide();
                $('.shade').hide();
            });
        })
        function changeColor(obj){
            $(obj).addClass('secCur').siblings().removeClass('secCur')
        }
    </script>
</head>

<body>
<div class="bigbox">
    <!--<p class="qijian_hide">服务器到期日期：<span>2015-11-21</span></p>-->
    <!--top-->
    <div class="topbox">
        <!--企悦社区-->
        <div class="top_01">
            <P>企悦社区</P>
        </div>
        <!--logo区域-->
        <div class="logobox">
            <div class="logo_width">
                <img src="<{$ipath}>index/images/top_logo.png" class="logo"/>
                <!--<span class="qijianban">旗舰版</span>
                <img src="<{$ipath}>index/images/top_01.png" class="arrow_01"/>-->
                欢迎您 <{$uname}>
                <div class="mine_account">
                    <!--头像区域-->
                    <div class="pic_box">

                    </div>
                    <!--我的账户-->
                    <!--下拉-->
                    <div class="account_box">
                        <p>我的账户</p>
                        <ul>
                            <li><a href="?g=user&m=member&a=company" target="to_right">公司设置</a></li>
                            <!--<li>账户充值</li>-->
                            <li><a href="?g=user&m=member&a=company&selnum=wx" target="to_right">公众号设置</a></li>
                            <li><a href="?g=user&m=member&a=company&selnum=alip" target="to_right">服务窗设置</a></li>
                            <li><a href="?g=user&m=member&a=company&selnum=alipay" target="to_right">支付宝设置</a></li>
                            <li><a href="?g=user&m=member&a=company&selnum=pass" target="to_right">修改密码</a></li>
                            <li><a href="?g=user&m=member&a=logout">退出</a></li>
                        </ul>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <!--menu-->
    <div class="containerbox">
        <div class="menubox">
            <div class="menu_list" style="display:<{if empty($plas)}>none;<{else}>block;<{/if}>">

                <p class="p_down pselect p_quan">我的快捷菜单</p>
                <ul class="menu_list_small">
                    <a href="<{$basehost}>?g=index&m=index&a=platform" target="to_right"  class="liselect moren"><li>我的服务</li></a>
                    <a href="<{$basehost}>?g=user&m=member&a=myMarke" target="to_right"><li>我要营销</li></a>
                    <a href="<{$basehost}>?g=user&m=member&a=myPromote" target="to_right"><li>我要推广</li></a>
                    <!--<li>内容管理</li>-->
                </ul>
            </div>
            <div class="menu_list" style="display:<{if in_array('3',$smarty.session.userinfo.gid)}>block;<{else}>none;<{/if}>">

                <p class="p_up p_quan">酒店行业</p>
                <ul class="menu_list_small ul_hide">
                    <div id="hotellink" style="display: <{if empty($hyid)}>none;<{else}>block;<{/if}>">
                    <a href="<{$basehost}>app/hotel/?m=manage&a=index" target="to_right"><li>房态图</li></a>
                    <a href="<{$basehost}>app/hotel/?m=order&a=beforeOrder" target="to_right"><li>预订客房</li></a>
                    <a href="<{$basehost}>app/hotel/?m=order&a=orderlist" target="to_right"><li>订房订单</li></a>
                    <a href="<{$basehost}>app/hotel/?m=manage&a=getRoomsByFtId" target="to_right"><li>酒店管理</li></a>
                    </div>
                    <a href="<{$basehost}>app/hotel/?m=manage&a=setBaseInfo" target="to_right"><li>酒店设置</li></a>
                </ul>
            </div>
            <!--
            <div class="menu_list" style="display:<{if in_array('4',$smarty.session.userinfo.gid) || in_array('5',$smarty.session.userinfo.gid)}>block;<{else}>none;<{/if}>">
                <p class="p_up p_quan"><a target="to_right" href="<{$basehost}>?g=user&m=member&a=loginToQiyue&mid=41">餐饮行业</a></p>
            </div>
            -->
            <div class="menu_list" style="display:<{if in_array('5',$smarty.session.userinfo.gid)}>block;<{else}>none;<{/if}>">
                <p class="p_up p_quan"><a target="to_right" href="<{$basehost}>?g=user&m=member&a=loginToQiyue&mid=41">餐饮行业</a></p>
                <p class="p_up p_quan"><a target="to_right" href="<{$basehost}>?g=user&m=member&a=loginToQiyue&mid=42">外卖行业</a></p>
            </div>

            <div class="menu_list" style="display:<{if in_array('7',$smarty.session.userinfo.gid)}>block;<{else}>none;<{/if}>">
                <p class="p_up p_quan"><a target="to_right" href="<{$basehost}>?g=user&m=member&a=loginToQiyue&mid=50">教育行业</a></p>
            </div>

            <div class="menu_list" style="display:<{if in_array('8',$smarty.session.userinfo.gid)}>block;<{else}>none;<{/if}>">
                <p class="p_up p_quan"><a target="to_right" href="<{$basehost}>?g=user&m=member&a=loginToQiyue&mid=51">房产行业</a></p>
            </div>

            <div class="menu_list" style="display:<{if in_array('9',$smarty.session.userinfo.gid)}>block;<{else}>none;<{/if}>">
                <p class="p_up p_quan"><a target="to_right" href="<{$basehost}>?g=user&m=member&a=loginToQiyue&mid=52">汽车行业</a></p>
            </div>

            <div class="menu_list" style="display:<{if in_array('10',$smarty.session.userinfo.gid)}>block;<{else}>none;<{/if}>">
                <p class="p_up p_quan"><a target="to_right" href="<{$basehost}>?g=user&m=member&a=loginToQiyue&mid=53">KTV行业</a></p>
            </div>

            <div class="menu_list" style="display:<{if in_array('11',$smarty.session.userinfo.gid)}>block;<{else}>none;<{/if}>">
                <p class="p_up p_quan"><a target="to_right" href="<{$basehost}>?g=user&m=member&a=loginToQiyue&mid=54">美容行业</a></p>
            </div>

            <div class="menu_list" style="display:<{if in_array('12',$smarty.session.userinfo.gid)}>block;<{else}>none;<{/if}>">
                <p class="p_up p_quan"><a target="to_right" href="<{$basehost}>?g=user&m=member&a=loginToQiyue&mid=55">宠物行业</a></p>
            </div>

            <div class="menu_list" style="display:<{if in_array('13',$smarty.session.userinfo.gid)}>block;<{else}>none;<{/if}>">
                <p class="p_up p_quan"><a target="to_right" href="<{$basehost}>?g=user&m=member&a=loginToQiyue&mid=56">食品行业</a></p>
            </div>

            <div class="menu_list" style="display:<{if in_array('14',$smarty.session.userinfo.gid)}>block;<{else}>none;<{/if}>">
                <p class="p_up p_quan"><a target="to_right" href="<{$basehost}>?g=user&m=member&a=loginToQiyue&mid=57">物业行业</a></p>
            </div>

            <div class="menu_list" style="display:<{if in_array('15',$smarty.session.userinfo.gid)}>block;<{else}>none;<{/if}>">
                <p class="p_up p_quan"><a target="to_right" href="<{$basehost}>?g=user&m=member&a=loginToQiyue&mid=58">酒店1.0</a></p>
            </div>
			
            <div class="menu_list" style="display:<{if in_array('6',$smarty.session.userinfo.gid)}>block;<{else}>none;<{/if}>">
                <p class="p_up p_quan"><a target="_blank" href="<{$shopurl}>">微商城</a></p>
            </div>
            
            <div class="menu_list">

                <p class="p_up p_quan">客户管理</p>
                <ul class="menu_list_small ul_hide">
                    <li><a href="?g=wx&m=weixin&a=fenlist" target="to_right">我的粉丝</a></li>
                    <{if $debug==1 || $debug=='1'}>
                        <li><a href="?g=wx&m=weixin&a=show_kf" target="to_right">多客服</a></li>
                    <li><a href="?g=wx&m=weixin&a=show_card" target="to_right">微信卡券</a></li>
                        <li><a href="?g=ucenter&m=ucenter&a=user" target="to_right">用户中心</a></li>
                    <{/if}>
                    <!--<li>我的盟友</li>-->
                </ul>
            </div>
        </div>

        <!--右侧-->
        <div class="content">
            <iframe class="content_iframe" allowtransparency="true" src="<{$basehost}>?g=index&m=index&a=platform" id="to_right" width="100%" name="to_right" frameborder="0" scrolling="yes" onload="resizeIframe()" style="min-height:1000px;"></iframe>
            <script type="text/javascript" language="javascript">
                function reinitIframe(){
                    var iframe = document.getElementById("to_right");
                    try{
                        var bHeight = iframe.contentWindow.document.body.scrollHeight;
                        var dHeight = iframe.contentWindow.document.documentElement.scrollHeight;
                        var height = Math.max(bHeight, dHeight);
                        iframe.height =  height;
                    }catch (ex){}
                }
                window.setInterval("reinitIframe()", 200);
            </script>
        </div>
    </div>
    <!--bottom-->
    <div class="bottombox">
        <div class="bottom_width">
            <div class="bottom01">
                <img src="<{$ipath}>index/images/bottom_01.png">
                <ul>
                    <li>中搜网络</li>
                    <li>股票代码:430339</li>
                </ul>
            </div>
            <!--复制-->
            <div class="bottom01  bottom_last" style="float:right">
                <img src="<{$ipath}>index/images/bottom_02.png">
                <ul>
                    <li>企悦微信服务号</li>
                    <li>最专业的移动互联网</li>
                    <li>企业微营销服务提供商</li>
                </ul>
            </div>
        </div>
        <!--copyright-->
        <div class="copyright">
            <P>
                <span>关于我们</span>
                <span>开放平台</span>
                <span>法律声明</span>
                <span>意见反馈</span>
                <span>中搜企悦版权所有 2005-2015</span>
                <span>京ICP证100943号</span>
            </P>
        </div>
    </div>
</div>
<!--弹出-->

<!--<div class="cd-popup" id="resubmit" role="alert">
    <div class="cd-popup-container">
        <p>你确定你要删除这个元素吗?</p>
        <ul class="cd-buttons">
            <li><a href="#">是</a></li>
            <li><a href="#">否</a></li>
        </ul>
        <a href="#" class="cd-popup-close img-replace" onClick="closediv()">关闭</a>
    </div>
</div>-->
<!--index弹出-->
<div class="shade">

</div>
<div id="above">
    <div class="layer">
        <header>
            <span class="title">标题</span>
            <span class="subTitle">副标题</span>
            <i></i>
        </header>
        <div class="first-sort-container">
            <ul class="first-sort fl">
                <li class="cur">微网站</li>
                <li>宣传展示类</li>
                <li>推广吸粉类</li>
                <li>营销活动类</li>
                <li>行业功能类</li>
            </ul>
        </div>
        <div class="whole-sec fl tab_box">
            <div class="sec-sort-container ">
                <ul class="sec-sort c16" >

                </ul>
            </div>
            <div class="sec-sort-container  disN">
                <ul class="sec-sort c5">

                </ul>
            </div>
            <div class="sec-sort-container  disN">
                <ul class="sec-sort c6 ">

                </ul>
            </div>
            <div class="sec-sort-container  disN">
                <ul class="sec-sort c7">

                </ul>
            </div>
            <div class="sec-sort-container  disN">
                <ul class="sec-sort c9">

                </ul>
            </div>
        </div>
        <div class="sort-content fl">
            <ul class="addd">

            </ul>

        </div>
    </div>
    </div>
    <script>
        $(document).ready(function(e) {
                    $.ajax({
                        type: "POST",
                        url: "?g=user&m=functiondata&a=index",
                        dataType: "json",
                        success: function (data) {
                            if (data.status == 1) {

                                for (ritem in data.msg) {
                                    var name = data.msg[ritem].name;
                                    var url = "<{$vqhost}>index.php?g=User&m="+data.msg[ritem].m + "&a=" + data.msg[ritem].a + "&" + data.msg[ritem].o +"token="+data.token ;
                                    //alert(url); return false;
                                    if (data.msg[ritem].classid == '16') {
                                       // var spanstr = "<li class='class_16' data-url="+  url +"' onclick='getmyurl(this)'>" + name + "</li>";
                                        var spanstr = "<li class='class_16' data-url="+  url +"' onclick='getmyurl(this)' >" + name + "</li><li class='class_16 mywebsite' onclick='showweb(this)'>我的网站</li>";
                                        $('.c16').append(spanstr);
                                    } else if (data.msg[ritem].classid == '5') {
                                        var spanstr = "<li class='class_5' data-url="+  url +"' onclick='getmyurl(this)' >" + name + "</li>";
                                        $('.c5').append(spanstr);
                                    } else if (data.msg[ritem].classid == '6') {
                                        var spanstr = "<li class='class_6' data-url="+  url +"' onclick='getmyurl(this)' >" + name + "</li>";
                                        $('.c6').append(spanstr);
                                    } else if (data.msg[ritem].classid == '7') {
                                        var spanstr = "<li class='class_7' data-url="+  url +"' onclick='getmyurl(this)' >" + name + "</li>";
                                        $('.c7').append(spanstr);
                                    } else if (data.msg[ritem].classid == '9') {
                                        var spanstr = "<li class='class_9' data-url="+  url +"' onclick='getmyurl(this)' >" + name + "</li>";
                                        $('.c9').append(spanstr);
                                    }
                                }
//				if ($('.c16>li').length>0) {
//					$('.c16').html(spanstr+'<li class="class_16 mywebsite" onclick="showweb(this)">我的网站</li>');
//				}
                            } else {
                                alert('error');
                                return false;
                            }
                        }
                    })
        });


function getmyurl(obj){
    var str=$(obj).attr("data-url");
    var bnum = str.indexOf("m=");
    var endnum = str.indexOf('&a');
    var url_m = str.substr((bnum+2),(endnum-bnum-2));
    //alert("index.php?g=user&m=functiondata&a="+url_m);
    $.ajax({
        type: "POST",
        url: "index.php?g=user&m=functiondata&a="+url_m ,
        dataType: "json",

        success:function(data){
            if(data.status ==1){
                var teststr = '';
                for(datainfo in data.item){
                     teststr += "<li><p>"+data.item[datainfo].name+"<input type='text' style='width:400px' value= "+data.item[datainfo].linkcode+"></p><div><span onclick='inserturl(this)'>插入</span><span><a href='"+data.item[datainfo].linkcode+"' target='_blank'>查看</a></span></div></li>"
                }

                $('.addd').html(teststr);
            }else{
                alert("暂时没有选择项，请先创建您的应用~！");
                return false;
            }
        }
    })
    $(obj).addClass('secCur').siblings().removeClass('secCur');//选中二级菜单变色操作
}
        function inserturl(o){
            //$('iframe').urladdress.value='123123';
            var link = $(o).next().children('a').attr('href');
           // window.frames["to_right"].document.getElementById("urladdress").value = link;
            window.frames["to_right"].$("#urladdress").val(link);
			window.frames["to_right"].$("#urladdress").focus();
            $('#above').hide();
            $('.shade').hide();

        }
	function showweb(obj){
		var html='';
		html += "<li><p>微信<input type='text' style='width:400px' value='<{$vqhost}>/index.php?g=Wap&m=Index&a=index&pla=4&token=<{$usertoken}>'></p><div><span onclick='inserturl(this)'>插入</span><span><a href='<{$vqhost}>/index.php?g=Wap&m=Index&a=index&pla=4&token=<{$usertoken}>' target='_blank'>查看</a></span></div></li>";
		html += "<li><p>APP<input type='text' style='width:400px' value='<{$vqhost}>/index.php?g=Wap&m=Index&a=index&pla=9&token=<{$usertoken}>'></p><div><span onclick='inserturl(this)'>插入</span><span><a href='<{$vqhost}>/index.php?g=Wap&m=Index&a=index&pla=9&token=<{$usertoken}>' target='_blank'>查看</a></span></div></li>";
		html += "<li><p>WAP<input type='text' style='width:400px' value='<{$vqhost}>/index.php?g=Wap&m=Index&a=index&pla=13&token=<{$usertoken}>'></p><div><span onclick='inserturl(this)'>插入</span><span><a href='<{$vqhost}>/index.php?g=Wap&m=Index&a=index&pla=13&token=<{$usertoken}>' target='_blank'>查看</a></span></div></li>";
		$('.addd').html(html);
		$(obj).addClass('secCur').siblings().removeClass('secCur');
	}

        function showhotel(){
            $('#hotellink').show();
        }
	
    </script>

</div>
</body>
</html>